Row redundancy for content addressable memory

ABSTRACT

A method and apparatus for performing row redundancy in a CAM device. For one embodiment, the CAM device includes a main CAM array having a plurality of rows of CAM cells, main match line control circuitry coupled to the main CAM array, a spare row of CAM cells, and a spare match line control circuit coupled to the spare row of CAM cells. The main CAM array includes a plurality of main match lines each coupled to one of the plurality of rows of CAM cells, and a plurality of main word lines each coupled to one of the plurality of rows of CAM cells. For one embodiment, the main match line control circuitry comprises a plurality of latch circuits each having a data input coupled to one of the main word lines, an output coupled to one of the main match lines, and a clock input responsive to a reset signal and a repair signal. The repair signal indicates whether one of the plurality or rows in the first main CAM array is to be replaced by the spare row of CAM cells. The repair signal is also provided to the spare match line control circuit to enable the spare row of CAM cells when a CAM cell in the main CAM array is determined to be defective. During a reset operation, the latch circuits force a mismatch state on the main match line of a row in the main CAM array that has a defective CAM cell.

FIELD OF THE INVENTION

The present invention relates generally to performing row redundancy in a content addressable memory (CAM) device.

BACKGROUND

Row and/or column redundancy has been used to improve the yield of memory devices such as static random access memory (SRAM) devices. A fuse element is typically placed in series with each word line in a main memory array. When a memory cell is determined to be defective, the fuse for the corresponding word line is blown to de-couple the main address decoder from the row incorporating the defective memory cell. The address of the defective row is programmed into a spare address decoder that selects a spare row of memory cells in response to subsequent read or write access operations to the defective address in the main memory array.

Traditional row redundancy techniques, however, do not scale well for content addressable memory (CAM) devices. A CAM device is a binary or ternary storage device that can simultaneously compare a specific pattern of comparand data with data stored in each row of CAM cells in its CAM array. Match results are reflected on match lines that are provided to a priority encoder that translates the matched location into a match address or CAM index for output from the CAM device. Each row of CAM cells is typically connected to a word line as in conventional SRAMs and at least one match line. Thus, in order to use traditional row redundancy techniques in a CAM array, each row of CAM cells would use a first fuse for the word line and a second fuse for the match line. Additionally, to ensure that the de-coupled match line did not provide erroneous data to the priority encoder, an additional pull-down circuit would be needed for each match line to guarantee that the de-coupled match line indicated a mismatch state for the defective row of CAM cells. The additional fuse per row, and pull-down circuitry per row, would increase the size of the CAM array. As fuses typically do not scale well with process technologies, this increase in the number of fuses is not readily remedied by migration to a smaller geometry fabrication process.

Thus, it would be desirable to provide a row redundancy scheme for CAMs that is more area efficient than using fuses on each word line and each match line.

SUMMARY OF THE INVENTION

A method and apparatus for performing row redundancy in a CAM device is disclosed. For one embodiment, the CAM device includes a main CAM array having a plurality of rows of CAM cells, main match line control circuitry coupled to the main CAM array, a spare row of CAM cells, and a spare match line control circuit coupled to the spare row of CAM cells. The main CAM array includes a plurality of main match lines each coupled to one of the plurality of rows of CAM cells, and a plurality of main word lines each coupled to one of the plurality of rows of CAM cells. For one embodiment, the main match line control circuitry comprises a plurality of latch circuits each having a data input coupled to one of the main word lines, an output coupled to one of the main match lines, and a clock input responsive to a reset signal and a repair signal. The repair signal indicates whether one of the plurality or rows in the first main CAM array is to be replaced by the spare row of CAM cells. The repair signal is also provided to the spare match line control circuit to enable the spare row of CAM cells when a CAM cell in the main CAM array is determined to be defective. During a reset operation, the latch circuits force a mismatch state on the main match line of a row in the main CAM array that has a defective CAM cell.

Other objects, features, and advantages of the present invention will be apparent from the accompanying drawings and from the detailed description that follows below.

BRIEF DESCRIPTION OF THE DRAWINGS

The features and advantages of the present invention are illustrated by way of example and are by no means intended to limit the scope of the present invention to the particular embodiments shown, and in which:

FIG. 1 is a block diagram of one embodiment of a CAM device including a spare CAM row;

FIG. 2 is a block diagram of one embodiment of the priority encoder of FIG. 1;

FIG. 3 is a block diagram of another embodiment of the priority encoder of FIG. 1;

FIG. 4 is a logic diagram of one embodiment of the main match line control circuitry and the spare match line control circuit of FIG. 1;

FIG. 5 is a circuit diagram of one embodiment of the repair indicator circuit of FIG. 1;

FIG. 6 is a circuit and logic diagram of one embodiment of the latch circuits of FIG. 4;

FIG. 7 is a circuit and logic diagram of another embodiment of the latch circuits of FIG. 4;

FIG. 8 is a block diagram of one embodiment of the spare address decoder of FIG. 1;

FIG. 9 is a circuit diagram of one embodiment of a programmable compare circuit of FIG. 8;

FIG. 10 is a circuit diagram of one embodiment of the spare address circuit of FIG. 1;

FIG. 11 is a block diagram of one embodiment of a CAM device having multiple spare rows for a main CAM array;

FIG. 12 is a block diagram of one embodiment of a CAM device having multiple main CAM arrays that share a main address decoder; and

FIG. 13 is a logic diagram of one embodiment of a redundancy clock generator circuit.

DETAILED DESCRIPTION

A method and apparatus for performing row redundancy in a CAM device is disclosed. In the following description, for purposes of explanation, specific nomenclature is set forth to provide a thorough understanding of the present invention. However, it will be apparent to one skilled in the art that these specific details may not be required to practice the present invention. In other instances, well-known circuits and devices are shown in block diagram form to avoid obscuring the present invention unnecessarily. Additionally, the interconnection between circuit elements or blocks may be shown as buses or as single signal lines. Each of the buses may alternatively be a single signal line, and each of the single signal lines may alternatively be buses. Additionally, the prefix symbol “/” or the suffix “B” attached to signal names indicates that the signal is an active low signal. Active low signals may be changed to active high signals as generally known in the art.

A method and apparatus for performing row redundancy in a CAM device is disclosed. The embodiments for performing row redundancy disclosed herein obviate the need for using fuses on the word lines and match lines in a CAM array. Thus, the size of the CAM array can be efficiently and compactly designed and fabricated without having to accommodate for the rather large fuses and any associated circuitry.

One embodiment of the present invention is shown in FIG. 1. CAM device 100 of FIG. 1 includes CAM array 101 that has a main CAM array 102 and spare or redundant CAM row 108. The spare CAM row is an independent row of CAM cells that can be enabled by spare match line control circuit 110 to replace a row of CAM cells in the main CAM array that has one or more defective CAM cells. The main CAM cells and spare CAM cells can be any type of CAM cells including binary or ternary CAM cells.

Spare CAM row 108 can be programmed to replace a defective row of CAM cells in main CAM array 102 as follows. Initially, the main CAM array is tested using any generally known testing methodology and hardware to determine if any of the CAM cells in the main CAM array are defective. When a defective CAM cell is detected, the address of the defective CAM cell is programmed into spare address decoder 122 and into spare address circuit 114. The programmed address becomes the address of the spare CAM row. For an alternative embodiment, spare address decoder 122 and spare address circuit 114 may be the same circuit or share programmable elements. Additionally, repair indicator circuit 120 is programmed to assert repair signal RPD to a high logic state on signal line 128. For an alternative embodiment, spare address decoder 122 or spare address circuit 114 may generate RPD. Programming of the spare address decoder and the repair circuit may be accomplished using conventional programming techniques including electrical programming or laser programming of fuses, or by programming or writing to volatile or nonvolatile memory elements.

FIG. 5 shows repair indicator circuit 500 that is one embodiment of the repair indicator circuit 120 of FIG. 1. Other embodiments may be used. Repair indicator circuit 500 includes a fuse element 502, transistor 504 and inverter 506. Fuse element 502 is coupled between power supply voltage VDD and the drain of transistor 504. Transistor 504 has its gate coupled to VDD and its source coupled to ground. Inverter 506 has its input coupled to the drain of transistor 504, and provides RPD from its output. Fuse element 502 may be an electrical or laser programmable fuse. For other embodiments, fuse 502 may be replaced with a programmable memory element including a volatile or nonvolatile memory element.

When CAM device 100 is powered for normal operation after initial testing, a reset signal RST is asserted to a high logic state to reset CAM device 100 to a known state. When programmed, spare address decoder 122 outputs the programmed spare address SA during the reset state to main address decoder 126 via address multiplexer 124. Main address decoder 126 may be any type of address decoder. Main address decoder 126 decodes SA and provides the decoded spare address to main match line control circuitry 104 and main CAM array 102 over signal lines 136. In response to RST indicating that a reset operation is being performed, and RPD indicating that main CAM array 102 has been repaired, main match line control circuitry 104 forces the match line of the defective row in main CAM array 102 to a mismatch state to disable the defective row from affecting compare operations on the main CAM array. The mismatch state is latched or registered such that when the reset operation is completed the mismatch state remains for the defective row. Main match line circuitry 104 performs the disabling function without using fuses on either the word lines or the match lines for the rows of CAM cells in main CAM array 102.

For an alternative embodiment, a row in main array 102 may be replaced by spare row 108 in response to an operation other than during a reset operation. For example, RST may be signal that indicates that a repair operation (e.g., in response to a “set repair” instruction) or a redundancy operation (e.g., in response to a “enable redundancy” instruction). Alternatively, RST may be a signal that indicates that power has been applied to CAM device 100 and CAM device auto-configures itself to determine if a repair has occurred and to perform the redundancy operation.

Each row of CAM cells in main array 102 may have one or more validity bits 106, and spare row 108 may have its own validity bit(s) 112. The validity bits indicate whether the corresponding rows of CAM cells are in a valid state or an empty state. A flag circuit (not shown) may monitor the state of validity bits 106 and 112 to identify a full condition for array 101. Array 101 is full when all of the non-defective rows of CAM cells in main CAM array 102 are filled with valid entries and spare CAM row 108 has a valid entry. In this state, match line control circuitry 104 may also cause the validity bit(s) 106 associated with the defective row in main array 102 to be set to a valid state in order to appropriately generate a full flag for array 101.

When RPD is asserted to a high logic state, spare match line control circuit 110 enables or activates spare CAM row 108 to operate as a row of CAM cells for main CAM array 102 and effectively replace the defective row in array 102. For one embodiment, RPD causes spare match line control circuit 110 to pre-charge the spare match line of spare CAM row 108. When RPD is asserted to a low logic state indicating that there is no defective row in main array 102, the spare match line control circuit forces the spare match line of spare CAM row 108 to a mismatch state such that it does not affect subsequent compare operations on main array 102. Spare match line control circuit 110 may directly force the spare match line to a mismatch state, for example, by discharging the spare match line. Alternatively, the spare match line control circuit may force a mismatch state by forcing the output of a comparison of comparand data and data stored in the spare row to always be a mismatch.

After the defective row in main CAM array 102 has been forced to a mismatch state, subsequent reads and writes to the address of the defective row will instead access spare CAM row 108. For example, a read or write operation to the address of the defective row (i.e., the programmed spare address) is performed as follows. Address AIN is simultaneously provided to main address decoder 126 and spare address decoder 122. AIN may be provided externally from another device or user, or internally, for example, as the next free address (NFA), the highest priority address, or a burst address. Spare address decoder 122 compares AIN with its programmed spare address. In there is a match, spare address decoder 122 asserts spare word line SWL to a high logic state to select spare CAM row 108 for the read or write operation. Reads and writes to spare CAM row 108 or main CAM array 102 may be performed by conventional read and write circuits (not shown). When the operation is a write operation, spare validity bit(s) 112 may also be updated to indicate that valid data is present in spare CAM row 108.

SWL is also provided to main address decoder 126. If SWL is asserted to a high logic state, spare CAM row 108 is selected and main address decoder 126 does not provide a decoded address to main CAM array 102. If SWL is asserted to a low logic state, then AIN does not match the programmed spare address and main address decoder 126 outputs a decoded input address to main array 102.

During a compare operation, comparand data is provided to and compared with data stored in both main CAM array 102 and spare CAM row 108. The comparison result with the data stored in spare CAM row 108 is reflected on spare match line SML 132, and the comparison results with the data stored in main CAM array 102 are reflected on main match lines MML 134. If SML indicates that there is a match between the comparand data and the data stored in spare CAM row 108, SML causes spare address circuit 114 to output the programmed spare address to priority encoder 118. Priority encoder 118 compares the spare address with the encoded address(es) of any other matching locations in main array 102, and outputs the highest priority matching address HPM on signal lines 130. HPM may be the address with the lowest value or the highest value.

When RPD is in a low logic state and the spare CAM row has not been enabled by spare match line control circuit 110, SML indicates a mismatch state. In this state, priority encoder 118 may ignore the output from spare address circuit 114 (i.e., it is an invalid address). For another embodiment, SML may be provided to priority encoder 118 to indicate whether priority encoder 118 should ignore the output of spare address circuit 114. Alternatively and/or additionally, priority encoder 116, or match flag circuit (not shown), may generate one or more match flag signals in response to MML and/or SML, and provide the match flag signal(s) to priority encoder 118 to indicate whether the encoded address output by priority encoder 116 (and/or spare address circuit 114) is valid or invalid.

Priority encoder 118 may be any type of priority encoder. Priority encoder 118 may also be formed from a compare circuit and a multiplexer as shown in FIGS. 2 and 3. FIG. 2 shows priority encoder 200 that includes compare circuit 202 and multiplexer 204. Compare circuit 202 compares the encoded addresses output by spare address circuit 114 and priority encoder 116, and indicates on signal line 206 which of the encoded addresses is the higher priority address. The higher priority address is then output by multiplexer 204 as HPM. Compare circuit 202 may also receive an indication of whether there is a match in spare CAM row 108 and/or main array 102 to determine whether to perform the comparison.

FIG. 3 shows priority encoder 300 that includes compare circuit 302 and multiplexer 304. Compare circuit 302 compares the encoded addresses output by spare address circuit 114 and priority encoder 116, and provides the higher priority address to one input of multiplexer 304. The other input of multiplexer 304 receives the output of priority encoder 116. Multiplexer 304 is controlled by RPD. When RPD is high indicating that a defective row has been replaced in main array 102, then multiplexer 304 provides the output of compare circuit 302 as HPM. Conversely, when RPD is low indicating that no defective row has been replaced in main array 102, then multiplexer 304 provides the output of priority encoder 116 as HPM. As with compare circuit 202, compare circuit 302 may also receive an indication of whether there is a match in spare CAM row 108 and/or main array 102 to determine whether to perform the comparison or output one of the encoded addresses directly to multiplexer 304. For another embodiment, multiplexer 304 may not be used, and HPM provided directly from compare circuit 302.

FIG. 4 shows main CAM array 402 that is one embodiment of main CAM array 102, spare CAM row 408 that is one embodiment of spare CAM row 108, main match line control circuitry 404 that is one embodiment of main match line control circuitry 104, and spare match line control circuit 410 that is one embodiment of spare match line control circuit 110. Main CAM array 402 includes an array of CAM cells 418 that may be any type of CAM cells including binary or ternary CAM cells. Each CAM cell is coupled to one of n word lines WL(0) through WL(n−1) that are coupled to main address decoder 126. Each CAM cell is also coupled to one of n main match lines MML(0) through MML(n−1). For other embodiments, there may be more than one main match line or more than one word line per row of CAM cells. Each CAM cell is also coupled to an independent pair of bit lines BL and BLB that provide write data and/or comparand data. For alternative embodiments, one or more separate comparand bit lines may be included to provide the comparand data to the CAM cells.

Main match line control circuitry 404 includes n latch circuits 406(0) through 406(n−1), where each latch is coupled to one of the rows of CAM cells in main array 402. Each latch has its data input coupled to the word line for that row of CAM cells, its inverted data output coupled to the main match line for that row of CAM cells, and its clock input coupled to a redundancy clock signal RCLK. RCLK is generated by timing generator 412 in response to RST, RPD, and/or a clock signal CLK. Timing generator 412 may be any clock generator circuit. For one embodiment, timing generator 412 may be a gated clock generator. For example, timing generator 412 may be an AND gate. The latch circuits may be transparent latches, D latches, other types of flip-flop circuits, or other types of memory circuits including volatile or nonvolatile memory circuits.

Spare CAM row 408 also includes a row of CAM cells 418 that are each coupled to spare word line SWL, spare match line SML, and a pair of bit lines BL and BLB. Spare match line control circuit 410 includes inverters 416 and 417 that control whether SML is pre-charged or discharged in response to RPD. SML is enabled or pre-charged by inverters 416 and 417 when RPD is in a high logic state, and is disabled or forced to a mismatch low logic state by inverters 416 and 417 when RPD is in low logic state. For an alternative embodiment, inverters 416 and 417 may be replaced by non-inverting buffer circuitry or other logic gates.

The operation of FIG. 4 to replace a row in main array 402 with spare row 408 is as follows. Assume that one of the CAM cells in row zero of main array 408 has been determined to be defective. In response, RPD is asserted to a high logic state, inverters 416 and 417 pre-charge or enable SML, and address zero is programmed into spare address decoder 122 and spare address circuit 114 of FIG. 1. During a reset operation, RST is asserted to a high logic state and address zero is provided to main address decoder 126. Main address decoder 126 decodes the address and asserts WL(0) to a high logic state, and asserts all other word lines to a low logic state. When timing generator 412 asserts RCLK to a high logic state, latch 406(0) drives MML(0) to a low logic state indicating a mismatch condition for row zero of main array 402. All other latches will drive the other main match lines to a high logic state effectively pre-charging these match lines. Thus, during the reset operation, the main match line of row zero is forced to a mismatch state, and the other main match lines and the spare match line are pre-charged. When match lines are pre-charged to a high logic state, subsequent compare operations that indicate a mismatch between one of the CAM cells 418 and comparand data will discharge the match line, while matches will leave the match line unaffected.

As indicated above, any latch circuit may be used for latches 406(0) through 406(n−1). FIGS. 6 and 7 shows two non-exhaustive embodiments. FIG. 6 shows latch 600 that includes pass transistor 602 and inverters 604 and 606. Pass transistor 602 provides the word line signal to the cross-coupled inverters 604 and 606 in response to RCLK. Latch 600 allows the complement of the logical state of WL to propagate through to MML when RCLK is high, and latches the state of MML when RCLK transitions to a low logic state.

FIG. 7 shows latch 700 that includes CMOS transmission gate 704, NAND gate 710, transistors 712 and 714, and inverters 702, 706 and 708. Transmission gate 704 has its gates coupled to RCLK and its logical complement RCLKB, an input terminal coupled to WL via inverter 702, and an output terminal coupled to the inputs of inverters 706 and 708. Inverter 708 has its output coupled to one input of NAND gate 710. NAND gate 710 has its other input coupled to RPD, and its output coupled to the inputs of inverters 706 and 708. Transistor 712 has its gate coupled to the output of inverter 706, its source coupled to ground, and its drain coupled to MML. P-channel transistor 714 is configured as a pre-charge circuit with its source coupled to VDD, its gate coupled to ground, and its drain coupled to the drain of transistor 712. Other pre-charge circuits may be used. Latch 700 allows the complement of the logical state of WL to propagate through to MML when RCLK is high and RPD is high, and latches the state of MML when RCLK transitions to a low logic state.

Any programmable spare address decoder may be used for spare address decoder 122 of FIG. 1. FIG. 8 shows spare address decoder 800 that is one embodiment of spare address decoder 122. Spare address decoder 800 includes m programmable compare circuits 804(m−1) to 804(0), one for each of m bits of the programmed spare address SA. Each programmable compare circuit is programmed with one bit of the spare programmed address SA. Unlike typical spare address decoders, the programmable compare circuits output the programmed spare address SA when RST is asserted to a high logic state. The RST signal is also provided as one input to a logic circuit that includes inverter 806 and AND gates 808 and 810. AND gate 808 has one input coupled to RST via inverter 806, and another input coupled to receive RPD. AND gates 810 has one input coupled to the output of AND gate 808, another input coupled to signal line 812, and provides SWL at its output. For another embodiment, AND gates 808 and 810 may be replaced with a single AND gate.

During read and write operations (RST logic low), each programmable compare circuit compares one bit of the input address AIN with one bit of the programmed spare address. If RPD is low, indicating that the spare CAM row is not enabled, AND gates 808 and 810 force SWL to a low logic state such that the spare CAM row is disabled from writing or reading operations. If RPD is a high logic state, then the logic state of SWL will be determined by the state of signal line 812. Signal line 812 is coupled to each of programmable compare circuits 804 and is pre-charged to a high logic state by pre-charge circuit 802. If AIN matches the programmed spare address stored in the programmable compare circuits, then signal line 812 remains pre-charged and SWL is asserted to a high logic state to select the spare CAM row. If, however, one of the bits of AIN does not match one of the SA bits, then signal line 812 is discharged and SWL deselected to a low logic state.

FIG. 9 shows programmable compare circuit 900 that is one embodiment of each of programmable compare circuits 804 of FIG. 8. Other embodiments may be used. Programmable compare circuit 900 includes programmable fuse 902 coupled in series with transistor 914 between signal line 812 and ground, and programmable fuse 904 coupled in series with transistor 920 between signal line 812 and ground. Fuses 902 and 904 may be programmed electrically, may be laser fuses, or may be any other type of programmable element including a memory element. When circuit 900 stores a logic zero, programmable fuse 902 is blown to de-couple signal line 812 from transistor 914. When circuit 900 stores a logic one, programmable fuse 904 is blown to decouple signal line 812 from transistor 920.

The gate of transistor 914 is controlled by AND gate 912, which has one of its inputs coupled to AINB (the logical complement of AIN), and another one of its inputs coupled to the logical complement of RST via inverter 910. The gate of transistor 920 is controlled by AND gate 908, which has one of its inputs coupled to AIN, and another one of its inputs coupled to the logical complement of RST via inverter 910. AND gate 908 also controls the gate of p-channel transistor 918 via inverter 906. Transistor 918 is coupled in series with transistor 916 between a power supply voltage and ground. Transistor 916 has its gate controlled by RST, and its drain is coupled to signal line 922 that carries one bit of SA. Node 922 is also coupled to the drain of transistor 914 and fuse 902.

When RST is high, transistors 920 and 914 are turned off such that the logical state of signal line 812 is not affected by circuit 900, and SA will be reflected on signal line 922. For example, if a zero is programmed into compare circuit 900, fuse 902 is blown and transistor 916 pulls signal line 922 to a low logic state when RST is high. If a one is programmed into compare circuit 900, fuse 904 is blown and the pre-charged state of signal line 812 pulls signal line 922 to a high logic state. Transistor 916 can be sized such that pre-charge circuit 802 can pull signal line 922 to a high logic state when transistor 916 is on.

When RST is low and a read or write operation is taking place, circuit 900 operates as follows. If AIN matches the programmed spare address bit, then the logical state of signal line 812 is unaffected by circuit 900. For example, if a zero is programmed into circuit 900, AIN is a low logic state, AINB is a high logic state, transistor 920 is off, and transistor 914 is on. Since fuse 902 is blown, there is no path to ground for signal line 812. Similarly, if a one is programmed into circuit 900, AIN is a high logic state, AINB is a low logic state, transistor 914 is off, and transistor 920 is on. Since fuse 904 is blown, there is no path to ground for signal line 812. If AIN does not match the programmed spare address bit, circuit 900 discharges signal line 812 to a low logic state such that SWL is deselected. For example, if a zero is programmed into circuit 900 and AIN is a high logic state (AINB is a low logic state), transistor 920 is on and fuse 904 is intact creating a discharge path for signal line 812 to ground. Similarly, if a one is programmed into circuit 900 and AIN is a low logic state (AINB is a high logic state), transistor 914 is on and fuse 902 is intact creating a discharge path for signal line 812 to ground.

FIG. 10 shows spare address circuit 1000 that is one embodiment of spare address circuit 114 of FIG. 1. Other embodiments may be used. For example, the spare address circuit may be combined with the spare address decoder such that only one group of fuses need to be programmed when the spare CAM row is enabled to replace a defective row in main array 102.

Spare address circuit 1000 includes a programmable circuit for each bit of the programmed spare address. The programmed spare address is provided to priority encoder 118 when spare match line SML is asserted to a high logic state indicating that there is a match between comparand data and data stored in the spare CAM row. Each programmable circuit of spare address circuit 1000 includes a pre-charge circuit 1002 coupled in series with a fuse element 1004 and transistor 1006 between a power supply voltage and ground. Each transistor 1006 has its gate coupled to SML. Fuses 1002(m−1) through 1002(0) may be programmed electrically, may be laser fuses, or may be any other type of programmable element including a memory element. Each bit of the programmed spare address is output on signal lines 1008(m−1)-1008(0), which are each coupled to the programmable circuits between the pre-charge circuits 1002(m−1)-1002(0) and the fuse elements 1004(m−1)-1004(0), respectively. A bit is programmed to a logic one by blowing the fuse element. A bit is effectively programmed to a logic zero by leaving the fuse element intact.

CAM array 101 of FIG. 1 includes a single spare CAM row 108 for main CAM array 102. In other embodiments, multiple spare rows may be available to replace multiple rows in main array 102. FIG. 11 shows CAM device 1100 that is one embodiment of CAM device 100 including two spare CAM rows 108 and 1102 for main CAM array 102. Associated with the additional spare CAM row 1102 is another spare match line control circuit 1104, spare validity bit(s) 1106, spare address decoder 1112, and spare address circuit 1108. Corresponding circuitry may be included for each additional spare CAM row included for main array 102. Spare address decoder 1112 receives RPD and may be programmed with the address of a second defective row in main array 102. During read and write operations, AIN is compared with the address stored in both of the spare address decoders, and the spare word lines SWL(1) and SWL(2) set to the appropriate logic states. As with SWL(1) output by spare address decoder 122, SWL(2) is provided by spare address decoder 1112 to main address decoder 126 to prevent the main address decoder from selecting the address of the defective row when there is a match with the programmed spare address in spare address decoder 1112.

During a reset, redundancy, or repair operation, spare address decoder 122 outputs the programmed spare address SA(1) to address multiplexer 124, and spare address decoder 1112 outputs programmed spare address SA(2) to address multiplexer 124. One-shot circuit 1114 and shift registers 1116 and 1118 control which programmed spare address is provided to main address decoder 126 at a particular time. One-shot circuit 1114 is responsive to a trigger signal that indicates that a reset, redundancy, or repair operation is taking place. RST is one embodiment of the trigger signal. When RST is asserted to a logic high state, one-shot circuit 1114 generates a one-shot pulse signal that causes shift register 1116 to output a logic high signal on signal line 1120 when CLK goes high. The signal of signal line 1120 causes spare address decoder 1112 to output SA(2) to main address decoder 126 via address multiplexer 124. Main address decoder 126 decodes SA(2) and provides the decoded spare address to main match line control circuitry 104 and main CAM array 102 over signal lines 136. In response, main match line control circuitry 104 forces the match line of the defective row in main CAM array 102 to a mismatch state to disable the defective row from affecting compare operations on the main CAM array. The mismatch state is latched or registered, as described above, such that when the reset operation is completed the mismatch state remains for the defective row. Spare CAM row 1102 is enabled to replace the row in main array 102 in response RPD.

On the next rising edge of CLK, the state of signal line 1120 is driven to a low logic state to stop spare address decoder 1112 from providing SA(2) to address multiplexer 124. This also causes shift register 1118 to output a logic one state to spare address decoder 122 on signal line 1122 such that SA(1) is provided to address multiplexer 124. Main address decoder 126 decodes SA(1) and provides the decoded spare address to main match line control circuitry 104 and main CAM array 102 over signal lines 136. Main match line control circuitry 104 forces the match line of the second defective row in main CAM array 102 to a mismatch state to disable the defective row from affecting compare operations on the main CAM array. The mismatch state is latched or registered such that when the reset operation is completed the mismatch state remains for the defective row. Spare CAM row 108 is enabled to replace the row in main array 102 in response to RPD.

For another embodiment, the outputs of shift registers 1116 and 1118 may be provided as select signals to address multiplexer 124 to select whether SA(1) or SA(2) is provided to main address decoder 126.

During a compare operation, comparand data is provided to and compared with data stored in main CAM array 102 and spare CAM rows 108 and 1102. The comparison result with the data stored in spare CAM row 108 is reflected on spare match line SML(1), the comparison result with the data stored in spare CAM row 1102 is reflected on spare match line SML(2), and the comparison results with the data stored in main CAM array 102 are reflected on main match lines MML 134. Spare match lines SML(1) and SML(2) control the output of the programmed spare addresses from spare address circuits 1108 and 114, respectively. Priority encoder 118 compares the outputs from circuits 114, 1108 and 116, and outputs the highest priority matching address HPM on signal lines 130.

The embodiment of FIG. 12 shows an example of how more than one spare CAM row may be used for a main array 102. Multiple CAM arrays with redundant or spare CAM rows can also be coupled together to form larger CAM arrays. FIG. 12 shows CAM device 1200 that includes CAM device 100 of FIG. 1 and another CAM array 1201. CAM array 1201 has addresses 0 to X, and CAM array 101 has addresses X+1 to N−1, where the combined arrays have a total of N addresses for storing N entries. CAM array 1201 includes a main CAM array 1202, main validity bits 1206, main match line control circuitry 1204, spare CAM row 1208, spare match line control circuit 1210, and spare validity bit 1212. The two CAM arrays share main address decoder 126, address multiplexer 124, and priority encoders 116 and 118. The second CAM array also has associated with it spare address decoder 1222, spare address circuit 1214, and repair indicator circuit 1220. Spare address decoder 1222 and spare address circuit 1214 each store a spare address SA(2) for spare CAM row 1208. Spare address decoder 1222 and spare address circuit 1214 may be combined into a single circuit. Repair indicator circuit asserts RPD(2) to a high logic state when a defective row of main array 1202 is replaced by spare CAM row 1208.

During read and write operations, AIN is compared with the address stored in both of the spare address decoders. If there is a match, spare word lines SWL(1) and SWL(2) are set to the appropriate logic state. As with SWL(1) output by spare address decoder 122, SWL(2) is provided by spare address decoder 1222 to main address decoder 126 to prevent the main address decoder from selecting the address of the defective row when there is a match with the programmed spare address in spare address decoder 1222.

During a reset, redundancy or repair operation, spare address decoder 122 outputs the programmed spare address SA(1) to address multiplexer 124, and spare address decoder 1222 outputs programmed spare address SA(2) to address multiplexer 124. One-shot circuit 1240 and shift registers 1242 and 1244 control which programmed spare address is provided to address multiplexer 124 and main address decoder 126 at a particular time. One-shot circuit 1240 is responsive to a trigger signal that indicates that a reset, redundancy, or repair operation is taking place. RST is one embodiment of the trigger signal. When RST is asserted to a logic high state, one-shot circuit 1240 generates a one-shot pulse signal that causes shift register 1242 to output a logic high signal on signal line 1246 when CLK goes high. The signal of signal line 1246 causes spare address decoder 1222 to output SA(2) to main address decoder 126 via address multiplexer 124. Main address decoder 126 decodes SA(2) and provides the decoded spare address to main match line control circuitry 1204 and main CAM array 1202. In response, main match line control circuitry 1204 forces the match line of the defective row in main CAM array 1202 to a mismatch state to disable the defective row from affecting compare operations on the main CAM array. The mismatch state is latched or registered, as described above, such that when the reset operation is completed the mismatch state remains for the defective row. Spare CAM row 1208 is enabled to replace the row in main array 1202 in response RPD(2).

On the next rising edge of CLK, the state of signal line 1246 is driven to a low logic state to stop spare address decoder 1222 from providing SA(2) to address multiplexer 124. This also causes shift register 1244 to output a logic one state to spare address decoder 122 such that SA(1) is provided to main address decoder 126 via address multiplexer 124. Main address decoder 126 decodes SA(1) and provides the decoded spare address to main match line control circuitry 104 and main CAM array 102 over signal lines 126. Main match line control circuitry 104 forces the match line of the second defective row in main CAM array 102 to a mismatch state to disable the defective row from affecting compare operations on the main CAM array. The mismatch state is latched or registered such that when the reset operation is completed the mismatch state remains for the defective row. Spare CAM row 1102 is enabled to replace the row in main array 102 in response RPD(1).

For another embodiment, the outputs of shift registers 1242 and 1244 may be provided as select signals to address multiplexer 124 to select whether SA(1) or SA(2) is provided to main address decoder 126.

During a compare operation, comparand data is provided to and compared with data stored in main CAM array 102, spare CAM rows 108, main CAM array 1202, and spare CAM row 1208. The compare operation may occur sequentially on array 1201 and then array 101, or it may occur simultaneously on the two arrays. The comparison result with the data stored in spare CAM row 108 is reflected on spare match line SML(1), the comparison result with the data stored in spare CAM row 1202 is reflected on spare match line SML(2), the comparison results with the data stored in main CAM array 102 is reflected on main match lines MML(1), and the comparison results with the data stored in main CAM array 1202 is reflected on main match lines MML(2). Spare match lines SML(1) and SML(2) control the output of the programmed spare addresses from spare address circuits 1214 and 114, respectively. Priority encoder 118 compares the outputs from circuits 114, 1214 and 116, and outputs the highest priority address as HPM on signal lines 130.

Additional CAM arrays can be added to CAM device 1200 to increase the number of available CAM entries. For each additional CAM array, another shift register is added to control when a programmed spare address will be provided to the common address multiplexer 124 and main address decoder 126.

When the main match line control circuitry of FIG. 12 is implemented as latch circuits as shown in FIG. 4, a timing generator such as timing generator 412 is used to generate the redundancy clock signal RCLK. The timing generator may also generate RCLK in response to the signals output from the shift registers such that the main match lines are not pre-charged or discharged by the latch circuits until the one-shot signal output by one of the shift registers has been asserted to a high logic state. For example, a timing generator associated with main match line control circuitry 104 may not pre-charge or discharge the main match lines MML(1) until the one-shot signal output by the shift register 1244 on signal on line 1248 has been asserted to a high logic state. For one embodiment, the timing generator may be an AND gate that logically combines RST, CLK, RPD and the output of the appropriate shift register. For another embodiment, the timing generator may be a gated clock generator. One embodiment of a gated clock generator is shown in FIG. 13.

Timing generator 1300 of FIG. 13 includes register 1304 and AND gates 1302 and 1306 that determine the state of RCLK in response to CLK. AND gate 1302 receives RST, RPD, and SHFTO (the output of one of shift registers 1242 or 1244) and drives the data input of register 1304. The data output of register 1304 is provided to AND gate 1306 and with CLK to generate RCLK. Timing generator 1300 also includes reset circuitry that resets RCLK to a low logic state after RST transitions to a high logic state and after RCLK transitions to a low logic state. The reset circuitry includes one-shot circuits 1308 and 1314, AND gate 1310, and OR gate 1312. When RST transitions to a logic high state and RPD is in a high logic state, one-shot circuit 1308 generates a pulse signal that causes AND gate 1310 and OR gate 1312 to reset register 1304. When RCLK transitions to a low logic state, one-shot circuit 1314 generates a pulse signal that causes OR gate 1312 to reset register 1304. Timing generator 1300 may also be used for CAM device 1100 of FIG. 11.

In the foregoing specification the invention has been described with reference to specific exemplary embodiments thereof. It will, however, be evident that various modifications and changes may be made thereto without departing from the broader spirit and scope of the invention. The specification and drawings are, accordingly, to be regarded in an illustrative rather than restrictive sense. 

What is claimed is:
 1. A content addressable memory (CAM) device comprising: a first main CAM array having a plurality of rows of CAM cells, each row coupled to a main match line; a first spare row of CAM cells coupled to a spare match line; and first replacement means for functionally replacing one of the plurality of rows of CAM cells in the first main CAM array with the first spare row of CAM cells.
 2. The CAM device of claim 1, wherein the first replacement means comprises: means for disabling one of the plurality of rows of CAM cells in the first main CAM array; and means for enabling the first spare row of CAM cells.
 3. The CAM device of claim 2, wherein the first main CAM array further comprises: a plurality of main word lines each coupled to one of the plurality of rows of CAM cells.
 4. The CAM device of claim 3, wherein the disabling means comprises a plurality of latch circuits each having a data input coupled to one of the main word lines, an output coupled to one of the main match lines, and a clock input responsive to a repair signal, wherein the repair signal indicates whether one of the plurality or rows in the first main CAM array is to be replaced by the first spare row of CAM cells.
 5. The CAM device of claim 4, wherein the clock input of each latch circuit is further responsive to a reset signal for the CAM device.
 6. The CAM device of claim 2, wherein the enabling means controls the logical state of the spare match line in response to a repair signal that indicates whether one of the plurality of rows in the first main CAM array is to be replaced by the first spare row of CAM cells.
 7. The CAM device of claim 6, wherein the enabling means comprises an inverter.
 8. The CAM device of claim 1 further comprising: a main address decoder coupled to the first main CAM array; a first spare address decoder coupled to the first spare row of CAM cells and the main address decoder; and a repair indicator circuit coupled to the first spare address decoder and the first replacement means.
 9. The CAM device of claim 8, further comprising: means for indicating that comparand data matches first data stored in the first spare row of CAM cells and second data stored in one of the plurality of rows of CAM cells in the first main CAM array; and means for determining whether the first spare row of CAM cells has an address that has a priority greater than an address corresponding to the row of CAM cells in the first main CAM array that stores the second data.
 10. The CAM device of claim 9, wherein the determining means comprises: a spare address circuit coupled to the first spare row of CAM cells and configured to store the address of the first spare row of CAM cells; a first priority encoder circuit coupled to the first main CAM array and configured to output an encoded address; and a second priority encoder coupled to receive the address of the first spare row of CAM cells and the encoded address.
 11. The CAM device of claim 10, wherein the second priority encoder comprises: a compare circuit coupled to receive the address of the first spare row of CAM cells and the encoded address, and having an output signalo that indicates which address is a higher priority; and a multiplexer coupled to output the address of the first spare row of CAM cells or the encoded address in response to the output signal of the compare circuit.
 12. The CAM device of claim 10, wherein the second priority encoder comprises: a compare circuit configured to output the higher priority address between the address of the first spare row of CAM cells and the encoded address; and a multiplexer configured to output the higher priority address or the encoded address in response to a repair signal that indicates whether one of the plurality or rows in the first main CAM array is replaced by the first spare row of CAM cells.
 13. The CAM device of claim 8, further comprising: a second spare row of CAM cells coupled to the first replacement means; and a second spare address decoder coupled to the second spare row of CAM cells and the main address decoder.
 14. The CAM device of claim 13, further comprising: a one-shot circuit configured to generate a one-shot signal in response to a trigger signal; and a shift register circuit coupled to receive the one-shot signal and coupled to the first and second spare address decoders.
 15. The CAM device of claim 13, wherein the trigger signal is a reset signal.
 16. The CAM device of claim 8 further comprising a multiplexer coupled between the first spare address decoder and the main address decoder.
 17. The CAM device of claim 1, further comprising: a second main CAM array having a plurality of rows of CAM cells; a second spare row of CAM cells; and second replacement means for functionally replacing one of the plurality of rows of CAM cells in the second main CAM array with the second spare row of CAM cells.
 18. The CAM device of claim 17, further comprising: a main address decoder coupled to the first and second main CAM arrays; a first spare address decoder coupled to the first spare row of CAM cells and the main address decoder; and a second spare address decoder coupled to the second spare row of CAM cells and the main address decoder; a first repair indicator circuit coupled to the first spare address decoder and the first replacement means; and a second repair indicator circuit coupled to the second spare address decoder and the second replacement means.
 19. The CAM device of claim 17, further comprising: a one-shot circuit configured to generate a one-shot signal in response to a reset signal; and a shift register circuit coupled to receive the one-shot signal and coupled to the first and second spare address decoders. 20.The CAM device of claim 19, wherein: the first main CAM array comprises a plurality of main word lines each coupled to one of the plurality of rows of CAM cells; and the first replacement means comprises a plurality of latch circuits each having a data input coupled to one of the main word lines, an output coupled to one of the main match lines, and a clock input responsive to a first clock signal.
 21. The CAM device of claim 20, further comprising clock generator circuit for generating the clock signal in response to a reset signal, a signal output by the shift register circuit, and a repair signal, wherein the repair signal indicates whether one of the plurality or rows in the first main CAM array is to be replaced by the first spare row of CAM cells.
 22. The CAM device of claim 17, wherein: the first main CAM array comprises a plurality of first main word lines each coupled to one of the plurality of rows of CAM cells of the first main CAM array; and the first replacement means comprises a first plurality of storage circuits each coupled to one of the first main word lines and the main match lines.
 23. The CAM device of claim 22, wherein: the second main CAM array comprises a plurality of second main match lines each coupled to one of the plurality of rows of CAM cells of the second main CAM array, and a plurality of second main word lines each coupled to one of the plurality of rows of CAM cells of the second main CAM array; and the second replacement means comprises a second plurality of storage circuits each coupled to one of a second main word lines and the second main match lines.
 24. A content addressable memory (CAM) device comprising: a main CAM array having a plurality of rows of CAM cells each coupled to a main match line; main match line control circuitry coupled to the main match lines of the main CAM array; a spare row of CAM cells coupled to a spare match line; and a spare match line control circuit coupled to the spare match line of the spare row of CAM cells.
 25. The CAM device of claim 24, wherein the main CAM array further comprises a plurality of main word lines each coupled to one of the plurality of rows of CAM cells.
 26. The CAM device of claim 25, wherein the main match line control circuitry comprises a plurality of latch circuits each having a data input coupled to one of the main word lines, an output coupled to one of the main match lines, and a clock input responsive to a repair signal, wherein the repair signal indicates whether one of the plurality or rows in the first main CAM array is to be replaced by the spare row of CAM cells.
 27. The CAM device of claim 26, wherein the clock input of each latch circuit is further responsive to a reset signal for the CAM device.
 28. The CAM device of claim 25, wherein the main match line control circuitry comprises a plurality of storage circuits each coupled to one of the main word lines, one of the main match lines, and a repair signal, wherein the repair signal indicates whether one of the plurality or rows in the first main CAM array is to be replaced by the spare row of CAM cells.
 29. The CAM device of claim 24, wherein the spare match line control circuit is configured to control the logical state of the spare match line in response to a repair signal that indicates whether one of the plurality or rows in the main CAM array is to be replaced by the spare row of CAM cells.
 30. The CAM device of claim 24, further comprising: a main address decoder coupled to the main CAM array; a spare address decoder coupled to the spare row of CAM cells and the main address decoder; and a repair indicator circuit coupled to the spare address decoder, the spare match line control circuit and the main match line control circuitry.
 31. The CAM device of claim 30, further comprising a multiplexer coupled between the spare address decoder and the main address decoder.
 32. The CAM device of claim 24, further comprising: means for indicating that comparand data matches first data stored in the spare row of CAM cells and second data stored in one of the plurality of rows of CAM cells in the main CAM array; and means for determining whether the spare row of CAM cells has an address that has a priority greater than an address corresponding to the row of CAM cells in the main CAM array that stores the second data.
 33. The CAM device of claim 32, wherein the determining means comprises: a spare address circuit coupled to the spare row of CAM cells and configured to store the address of the spare row of CAM cells; a first priority encoder circuit coupled to the main CAM array and configured to output an encoded address; and a second priority encoder coupled to receive the address of the spare row of CAM cells and the encoded address.
 34. The CAM device of claim 33, wherein the second priority encoder comprises: a compare circuit coupled to receive the address of the spare row of CAM cells and the encoded address, and having an output signal that indicates which address is a higher priority; and a multiplexer coupled to output the address of the spare row of CAM cells or the encoded address in response to the output signal of the compare circuit.
 35. The CAM device of claim 33, wherein the second priority encoder comprises: a compare circuit configured to output the higher priority address between the address of the spare row of CAM cells and the encoded address; and a multiplexer configured to output the higher priority address or the encoded address in response to a repair signal that indicates whether one of the plurality or rows in the main CAM array is replaced by the first spare row of CAM cells.
 36. A method of replacing a defective row of content addressable memory (CAM) cells, comprising: disabling a match line of the defective row of CAM cells; and enabling a spare match line of a spare row of CAM cells.
 37. The method of claim 36, wherein the disabling comprises: asserting a word line of the defective row to a predetermined logic state; and asserting the match line of the defective row to a mismatch state in response to the logic state of the word line.
 38. The method of claim 37, wherein the word line of the defective row is asserted to the predetermined logic state in response to a repair signal that indicates that defective row is replaced.
 39. A method of replacing a defective row of content addressable memory (CAM) cells, comprising: asserting a word line of the defective row to a predetermined logic state; asserting a match line of the defective row to a mismatch state state of the word line; and enabling a spare row of CAM cells coupled to a spare match line to replace the defective row of CAM cells.
 40. The method of claim 39, wherein the word line of the defective row is asserted to the predetermined logic state in response to a repair signal that indicates that defective row is replaced.
 41. The CAM device of claim 3, wherein the disabling means comprises a plurality of storage circuits each coupled to one of the main word lines, one of the main match lines, and a repair signal, wherein the repair signal indicates whether one of the plurality of rows in the first main CAM array is to be replaced by the first spare row of CAM cells.
 42. A content addressable memory (CAM) device comprising: a main CAM array having a plurality of rows of CAM cells each coupled to a main match line; a spare row of CAM cells coupled to a spare match line, and a main match line control circuit coupled to the main CAM array and operable to assert to a mismatch state the main match line associated with a defective row of CAM cells in the main CAM array.
 43. The CAM device of claim 42, wherein the main CAM array further comprises a plurality of main word lines each coupled to one of the plurality of rows of CAM cells.
 44. The CAM device of claim 43, wherein the main match line control circuit comprises a plurality of storage circuits each coupled to one of the main word lines, one of the main match lines, and a repair signal, wherein the repair signal indicates whether the main match line control circuit asserts the main match line of the defective row of CAM cells to a mismatch state.
 45. The CAM device of claim 44, wherein the plurality of storage circuits are further coupled to a reset signal.
 46. The CAM device of claim 42, further comprising: a main address decoder coupled to the main match line control circuit; and a first spare address decoder coupled to the spare row of CAM cells.
 47. The CAM device of claim 46, further comprising a repair indicator circuit coupled to the spare address decoder and the main address decoder.
 48. The CAM device of claim 42, further comprising a spare match line control circuit coupled to the spare match line.
 49. The CAM device of claim 48, further comprising a repair indicator circuit coupled to the main match line control circuit and the spare match line control circuit.
 50. The CAM device of claim 42, further comprising: a spare address circuit coupled to the spare row of CAM cells and configured to store the address of the spare row of CAM cells; a first priority encoder circuit coupled to the main CAM array and configured to output an encoded address; and a second priority encoder coupled to receive the address of the spare row of CAM cells and the encoded address.
 51. The CAM device of claim 50, wherein the second priority encoder comprises: a compare circuit coupled to receive the address of the spare row of CAM cells and the encoded address, and having an output signal that indicates which address is a higher priority; and a multiplexer coupled to output the address of the spare row of CAM cells or the encoded address in response to the output signal of the compare circuit.
 52. The CAM device of claim 50, wherein the second priority encoder comprises: a compare circuit configured to output the higher priority address between the address of the spare row of CAM cells and the encoded address; and a multiplexer configured to output the higher priority address or the encoded address in response to a repair signal that indicates whether one of the plurality or rows in the main CAM array is replaced by the spare row of CAM cells.
 53. A method of replacing a defective row of content addressable memory (CAM) cells, comprising: asserting a match line of the defective row of CAM cells to a mismatch state; and enabling a spare match line of a spare row of CAM cells to indicate a match when comparand data matches data stored in the spare row of CAM cell. 